/*
 * @Description: 
 * @Author: lucl
 * @Date: 2021-06-29 08:44:56
 * @LastEditors: Ronda
 * @LastEditTime: 2021-07-01 14:58:44
 */
import Vue from 'vue'
import VueRouter from 'vue-router'
// import Home from '../views/Home.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/login',
    name: 'Login',
    component: () => import('@/views/Login')
  },


  {
    path: '/',
    name: 'Home',
    redirect: '/mine',
    component: () => import('@/views/Home'),
    // 子路由
    children: [
      // 首页路由
      {
        path: 'index',
        name: 'Index',
        component: () => import(/* webpackChunkName: "about" */ '@/views/home/Index')
      },
      // 订单
      {
        path: 'order',
        name: 'Order',
        component: () => import(/* webpackChunkName: "about" */ '@/views/home/Order'),

      },
      // 订单详情
      {
        path: 'order_detail',
        name: 'Order_Detail',
        component: () => import('@/views/home/Order_detail')
      },

      // 收益路由
      {
        path: 'money',
        name: 'Money',
        component: () => import(/* webpackChunkName: "about" */ '@/views/home/Money')
      },
      {
        path: '/mine',
        name: 'Mine',
        component: () => import(/* webpackChunkName: "about" */ '@/views/home/Mine')
      }
    ],
  },
     //实名认证路由
  {
    path: '/authorization',
    name: 'Authorization',
    component: () => import('@/views/Mine/Authorization')
  },
    //个人信息路由
  {
    path: '/authentication_details',
    name: 'Authentication_details',
    component: () => import('@/views/Mine/Authentication_details')
  },
]

const router = new VueRouter({
  mode: 'hash',
  base: process.env.BASE_URL,
  routes
})

export default router
